<template>
    <el-drawer v-model="table" title="编辑统计组件" direction="rtl" size="50%" v-on:close="Load()">
        <el-form :model="form" label-width="120px">
            <el-form-item label="统计组件标题">
                <el-input v-model="table.data.statistic_title" />
            </el-form-item>
            <el-form-item label="统计组件值">
                <el-input v-model="table.data.statistic_value" type="textarea" />
            </el-form-item>
        </el-form>
        <el-button type="success" v-on:click="Edit()">编辑</el-button>
    </el-drawer>
</template>
<script setup lang="ts">
import { ref, reactive, onMounted } from 'vue'
import { Load } from '../../../style.js'
import {EditStatistic} from '../../../service/Statistic.js'



const props = defineProps({
    data: Object,
})

const table = ref(props)
const form = ref()


const Edit = () =>{

    const data = {Id:props.data.statistic_id,title:props.data.statistic_title,value:props.data.statistic_value}
    EditStatistic(data).then((res)=>{

    })
}


</script>
<style></style>